package org.jaaksi.demo.ptr.ui.recycler;

import android.view.View;
import org.jaaksi.demo.ptr.api.NetApi;
import org.jaaksi.demo.ptr.bean.house.HouseListBean;
import org.jaaksi.demo.ptr.bean.house.MainResponse;
import org.jaaksi.demo.ptr.bean.response.Result;
import retrofit.call.SimpleCallback;
import retrofit.util.ServiceGenerator;
import retrofit2.Call;

/**
 * Created by an on 2017/5/11.<br/>
 */

public class MyListFragment extends BaseRecyclerViewFragment<HouseListBean> {
  @Override protected void init(View view) {
  }

  @Override protected void buildRequest() {
    Call<Result<MainResponse>> call = ServiceGenerator.createService(NetApi.class)
        .getMainResponse("110000", getOffset(), getPageSize());
    call.enqueue(new SimpleCallback<Result<MainResponse>>() {
      @Override public void onResponse(Call<Result<MainResponse>> call, Result<MainResponse> entity,
          boolean isSuccess) {

      }
    });
  }
}
